using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Resources;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;

namespace KPIS.GERP.Models.ICM
{
	[DataContract, Table("IcmPurchaseOrderContractCollateral")]
    public class PurchaseOrderContractCollateral
    {

		[Key, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
		[DataMember, Display(Name = "IcmPoConColId", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public int IcmPoConColId { get; set; }

		[ForeignKey("IcmColType")]
		[DataMember, Display(Name = "IcmColTypeId", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public Nullable<int> IcmColTypeId { get; set; }

		[DataMember, Display(Name = "IcmPoConColRefNo", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public string IcmPoConColRefNo { get; set; }

		[DataMember, Display(Name = "IcmPoConColAmount", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public Nullable<double> IcmPoConColAmount { get; set; }

		[DataMember, Display(Name = "IcmPoConColDescr", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public string PoConColDescr { get; set; }

        [ForeignKey("PurchaseOrder")]
		[DataMember, Display(Name = "PoId", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public Nullable<int> PoId { get; set; }

		[DataMember, Display(Name = "ReceiptNo", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public string ReceiptNo { get; set; }

		[DataMember, Display(Name = "CreatedBy", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public Nullable<int> CreatedBy { get; set; }

		[DataMember, Display(Name = "CreatedWhen", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public Nullable<System.DateTime> CreatedWhen { get; set; }

		[DataMember, Display(Name = "UpdatedBy", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public Nullable<int> UpdatedBy { get; set; }

		[DataMember, Display(Name = "UpdatedWhen", ResourceType = typeof(Resources.PurchaseOrderContractCollateralResource))]
        public Nullable<System.DateTime> UpdatedWhen { get; set; }

		public virtual  ICM.SysCollateralType IcmColType { get; set; }

        public virtual PurchaseOrder PurchaseOrder { get; set; }

    }
}